import React from 'react'
import { useNavigate,Outlet } from 'react-router-dom'

export default function Music() {

  const navigate = useNavigate()

  return (
    <div style={{background:'yellowgreen'}}>
      <h1>Music</h1>
      {/* 
        params传参
       
      */}
      <div>
        <button onClick={()=>{
          navigate('/home/music/item/华语/1')
        }}>华语音乐</button>
        <button onClick={() => {
          navigate("/home/music/item/港台/2")
        }}>港台音乐</button>
        <button onClick={() => {
          navigate("/home/music/item/欧美/3")
        }}>欧美音乐</button>
      </div>

      <Outlet />

    </div>
  )
}
